<template>
  <div class="pending-problem">
    <div class="pending-problem-item" v-for="item in problem">
      <div class="code">{{item.code}}</div>
      <div class="title">{{item.title}}</div>
      <div class="name">{{item.name}}</div>
      <div class="level" :style="{color:item.color.color,background:item.color.background,borderColor:item.color.color}">{{item.levelText}}</div>
      <div class="btn view">查看</div>
      <div class="btn handle">处理</div>
    </div>
  </div>
</template>
<script>
export default {
  name: 'PendingProblem',
  data(){
    return{
      problem:[
        {code:'#202406-015',title:'垃圾堆放',name:'王*',levelText:'高',color: {color:'#EA0000',background:'rgba(234,0,0,0.2)'}},
        {code:'#202406-016',title:'噪音投诉',name:'李*',levelText:'中',color: {color:'#FED52F',background:'rgba(254,213,47,0.2)'}},
        {code:'#202406-017',title:'停车纠纷',name:'张*',levelText:'高',color: {color:'#EA0000',background:'rgba(234,0,0,0.2)'}},
        {code:'#202406-018',title:'公共设施',name:'刘*',levelText:'中',color: {color:'#FED52F',background:'rgba(254,213,47,0.2)'}},
        {code:'#202406-019',title:'绿化问题',name:'陈*',levelText:'低',color: {color:'#32B4FF',background:'rgba(50,180,255,0.2)'}},
        {code:'#202406-020',title:'楼道照明',name:'赵*',levelText:'中',color: {color:'#FED52F',background:'rgba(254,213,47,0.2)'}},
        {code:'#202406-021',title:'宠物管理',name:'孙*',levelText:'高',color: {color:'#EA0000',background:'rgba(234,0,0,0.2)'}},
      ]
    }
  }
}
</script>
<style scoped lang="scss">
.pending-problem{
  width: 100%;
  height: 100%;
  overflow: auto;
  &::-webkit-scrollbar {
    width: 4px;
  }
  &::-webkit-scrollbar-thumb {
    border-radius: 3px;
    background: rgba(0,198,255,.3);
  }
  &::-webkit-scrollbar-track{
    border-radius: 3px;
    background: rgba(0,24,48,.3);
  }
  .pending-problem-item{
    width: 100%;
    height: 55px;
    padding: 0 20px;
    display: flex;
    align-items: center;
    background: #06213B;
    border-radius: 5px;
    border: 1px solid #31B2FD;
    margin-bottom: 10px;
    .code{
      color: #32B3FE;
      font-size: 14px;
      margin-right: 15px;
      font-weight: bold;
    }
    .title,.name{
      font-size: 14px;
      color: #fff;
      margin-right: 15px;
    }
    .name{
      flex-grow: 1;
    }
    .level,.btn{
      padding: 1px 8px;
      border-radius: 3px;
      font-size: 12px;
      border: 1px solid;
      margin-left: 10px;
    }
    .btn{
      cursor: pointer;
      &.view{
        color: #32B3FE;
        background: rgba(50,180,255,0.2);
        border-color: #32B3FE;
      }
      &.handle{
        color: #22DFE9;
        background: rgba(34, 223, 233, 0.2);
        border-color: #22DFE9;
      }
    }
  }
}
</style>
